package com.gxg.entities;

import org.json.JSONObject;

import javax.persistence.Entity;
import javax.persistence.Id;
import java.sql.Timestamp;

/**
 * By 李朋飞
 **/
@Entity
public class Video {

    @Id
    private String id;

    private String parentTitle;
    private String childTitle;
    private String videoWebUrl;
    private String videoLocalUrl;
    private String parentImgWebUrl;
    private String parentImgLocalUrl;
    private String childImgWebUrl;
    private String childImgLocalUrl;
    private String teacherId;
    private String videoClass;
    private Timestamp createTime;
    private Timestamp modificationTime;
    public String toString()
    {
        JSONObject jsonObject = new JSONObject();
        jsonObject.accumulate("parentTitle", this.parentTitle);
        jsonObject.accumulate("childTitle", this.childTitle);
        jsonObject.accumulate("videoWebUrl", this.videoWebUrl);
        jsonObject.accumulate("videoLocalUrl", this.videoLocalUrl);
        jsonObject.accumulate("parentImgWebUrl", this.parentImgWebUrl);
        jsonObject.accumulate("parentImgLocalUrl", this.parentImgLocalUrl);
        jsonObject.accumulate("childImgWebUrl", this.childImgWebUrl);
        jsonObject.accumulate("childImgLocalUrl", this.childImgLocalUrl);
        jsonObject.accumulate("teacherId", this.teacherId);
        jsonObject.accumulate("videoClass", this.videoClass);
        jsonObject.accumulate("createTime", this.createTime);
        jsonObject.accumulate("modificationTime", this.modificationTime);
        return jsonObject.toString();
    }
    public Video(){

    }

    public Video(String id, String parentTitle, String childTitle, String videoWebUrl, String videoLocalUrl, String parentImgWebUrl, String parentImgLocalUrl, String childImgWebUrl, String childImgLocalUrl, String teacherId, String videoClass, Timestamp createTime, Timestamp modificationTime) {
        this.id = id;
        this.parentTitle = parentTitle;
        this.childTitle = childTitle;
        this.videoWebUrl = videoWebUrl;
        this.videoLocalUrl = videoLocalUrl;
        this.parentImgWebUrl = parentImgWebUrl;
        this.parentImgLocalUrl = parentImgLocalUrl;
        this.childImgWebUrl = childImgWebUrl;
        this.childImgLocalUrl = childImgLocalUrl;
        this.teacherId = teacherId;
        this.videoClass = videoClass;
        this.createTime = createTime;
        this.modificationTime = modificationTime;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getParentTitle() {
        return parentTitle;
    }

    public void setParentTitle(String parentTitle) {
        this.parentTitle = parentTitle;
    }

    public String getChildTitle() {
        return childTitle;
    }

    public void setChildTitle(String childTitle) {
        this.childTitle = childTitle;
    }

    public String getVideoWebUrl() {
        return videoWebUrl;
    }

    public void setVideoWebUrl(String videoWebUrl) {
        this.videoWebUrl = videoWebUrl;
    }

    public String getVideoLocalUrl() {
        return videoLocalUrl;
    }

    public void setVideoLocalUrl(String videoLocalUrl) {
        this.videoLocalUrl = videoLocalUrl;
    }

    public String getParentImgWebUrl() {
        return parentImgWebUrl;
    }

    public void setParentImgWebUrl(String parentImgWebUrl) {
        this.parentImgWebUrl = parentImgWebUrl;
    }

    public String getParentImgLocalUrl() {
        return parentImgLocalUrl;
    }

    public void setParentImgLocalUrl(String parentImgLocalUrl) {
        this.parentImgLocalUrl = parentImgLocalUrl;
    }

    public String getChildImgWebUrl() {
        return childImgWebUrl;
    }

    public void setChildImgWebUrl(String childImgWebUrl) {
        this.childImgWebUrl = childImgWebUrl;
    }

    public String getChildImgLocalUrl() {
        return childImgLocalUrl;
    }

    public void setChildImgLocalUrl(String childImgLocalUrl) {
        this.childImgLocalUrl = childImgLocalUrl;
    }

    public String getTeacherId() {
        return teacherId;
    }

    public void setTeacherId(String teacherId) {
        this.teacherId = teacherId;
    }

    public String getVideoClass() {
        return videoClass;
    }

    public void setVideoClass(String videoClass) {
        this.videoClass = videoClass;
    }

    public Timestamp getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }

    public Timestamp getModificationTime() {
        return modificationTime;
    }

    public void setModificationTime(Timestamp modificationTime) {
        this.modificationTime = modificationTime;
    }
}
